<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>{{ title }}</title>
    <link rel="stylesheet" href="{{ url_for('static', filename='css/clock.css') }}">
    <link rel="stylesheet" href="{{ url_for('static', filename='css/base.css') }}">
    <script></script>
    {% block added_style %}{% endblock %}
</head>
<body>
    <script src="https://cdn.bootcss.com/jquery/3.4.1/jquery.min.js"></script>
    <script src="{{ url_for('static', filename='css//clock.js') }}"></script>
    <header>
        <nav>
            <ul>
                <li id="nav_name" >BJDragon</li>
                <li>
                    当前时间：<span class="clock" id="current-time"></span>
                </li>
                <!-- 灵动岛用于展示信息 -->
                <li id="island">一些跳动信息</li>
                {% if g.user %}
                    <li><span>当前用户：{{ g.user['username'] }}</span>
                    <li><a href="{{ url_for('auth.logout') }}">Log Out</a>
                {% else %}
                    <li><a href="{{ url_for('auth.register') }}">Register</a>
                    <li><a href="{{ url_for('auth.login') }}">Log In</a>
                {% endif %}
            </ul>
        </nav>
        <span><a href="https://gitee.com/BJDragon/coze_app" target="_blank">项目地址</a></span>
    </header>

    <main>
      
        {% block main %}
        <!-- 三列内容区域 -->
        <div class="main-container">
            <!-- 第一列：动态加载 JSON 数据 -->
            <div class="content-box" id="col_box1">
                <p style="text-align: center; color: #3d79cc;">昨日知识点回顾</p>
                <!-- {% block content %}{% endblock %} -->
                {% block content_last_data %}{% endblock %}
            </div>
            
            <!-- 第二列和第三列的内容 -->
            <div class="content-box" id="col_box2">
                <p>今日学习要点</p>
                {% block today_record_data %}{% endblock %}
                <a href="{{ url_for('blog.create') }}">New</a>
                <!-- {% block createNew %}{% endblock %} -->
                <!-- <div class="today_done">today_done</div>
                <div class="create_new" >create_new</div> -->
            </div>

            <div class="content-box" id="col_box3">
                <p>一些新闻热点</p>
                {% block news_data %}
                {% endblock %}
            </div>
            
        </div>
        {% endblock %}
    </main>

    <!-- <footer>
        <p>&copy; 2024 Flask 测试示例</p>
    </footer> -->

    <script src="{{ url_for('static', filename='js/index.js') }}"></script>
</body>
</html>
